

package com.hazelcast.scheduledexecutor.impl.operations;

import com.hazelcast.scheduledexecutor.impl.ScheduledExecutorDataSerializerHook;
import com.hazelcast.scheduledexecutor.impl.ScheduledTaskResult;
import com.hazelcast.scheduledexecutor.impl.ScheduledTaskStatisticsImpl;

import java.util.Map;

public class SyncBackupStateOperation extends SyncStateOperation {

    public SyncBackupStateOperation() {
    }

    public SyncBackupStateOperation(String schedulerName, String taskName, Map state, ScheduledTaskStatisticsImpl stats, ScheduledTaskResult result) {
        super(schedulerName, taskName, state, stats, result);
    }

    @Override
    public void run() throws Exception {
        getContainer().syncState(taskName, state, stats, result);
    }

    @Override
    public int getClassId() {
        return ScheduledExecutorDataSerializerHook.SYNC_BACKUP_STATE_OP;
    }

}
